import http from '@/utils/request'

//查询用户订单信息
export async function getUserOrdersApi(parm){
  return await http.get("/orders",parm)
}

//建立订单
export async function addNewOrdersApi(parm){
  return await http.post("/orders",parm)
}

//建立充值订单
export async function addRechargeOrdersApi(parm){
  return await http.post("/orders/recharge",parm)
}

//完成支付
export async function finishPayApi(parm){
  return await http.put("/orders",parm)
}

//取消订单
export async function cancelOrderApi(parm){
  return await http.put("/orders/cancel",parm)
}
